﻿<%@ Page Language="C#"  Inherits="E.Web.Teacher.internals.publics.classes_public.Edit" %>
<%@ Import Namespace="E.Model" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
  <title>班级信息</title>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />  
  <link rel="stylesheet" href="/css/main.css" type="text/css" media="all" />
  <link rel="stylesheet" href="/css/t_main.css" type="text/css" media="all" />
  <script type="text/javascript" src="/js/Common.js"></script>
  <script type="text/javascript">
    function CheckClassForm(act) {
      var code = document.getElementById("ClassCodeTxt").value;
      if (code == "" (act == "n" && document.getElementById("CourseSlt").value == "-1")) {
        alert("请正确填写信息");
        return false;
      } else {
        return true;
      }
    }
  </script>
</head>
<body>
  <form id="form1" action="" method="post">
    <div class="m_top"></div>
    <div class="block">
      <div style="width:650px; height:22px;">
        <div class="title">&nbsp;班级信息填写</div>
      </div>
      <div class="spe_line_2"></div>
      <div class="box_1">
        <div class="fl tr left"><span class="hint">*</span>班级编号：</div>
        <div class="fl"><input type="text" id="ClassCodeTxt" name="ClassCodeTxt" maxlength="50" value="<%=model.ClassCode %>" /></div>
      </div>
      <% if (act == "u") { %>
      <div class="box_1">
        <div class="fl tr left">项目及课程：</div>
        <div class="fl dis_r"><%=model.ProjectName%>--<%=model.CourseName %></div>
      </div>
      <% } else { %>
      <div class="box_1">
        <div class="fl tr left"><span class="hint">*</span>项目及课程：</div>
        <div class="fl">
          <select id="CourseSlt" name="CourseSlt">
            <option value="-1">请选择课程</option>
            <% foreach (System.Collections.Generic.KeyValuePair<int, string> kvp in courseList) { %>
            <option value="<%=kvp.Key %>"><%=kvp.Value %></option>
            <% } %>
          </select>
        </div>
      </div>
      <% } %>
      <input type="hidden" id="act" name="act" value="<%=act %>" />
      <input type="hidden" id="id" name="id" value="<%=id %>" />
      <div style="width:350px; margin-top:20px; text-align:center;">
        <input type="image" src="/images/btn/confirm.gif" style="width:52px; height:22px;" onclick="return CheckClassForm('<%=act %>');" />
        <% if (act == "u") { %>
        &nbsp;&nbsp;<a href="/internals/publics/classes_public/List.aspx"><img alt="" src="/images/btn/back.gif" /></a>
        <% } %>
      </div>
    </div>
  </form>
  
</body>
</html>
